
const bodyParser = require('koa-bodyparser')
// const router = require('koa-router')()
const Koa = require('koa')



const app =new Koa()
app.use(bodyParser())

const cors = require('koa-cors')
app.use(cors())


const routes = require('./routes/index');

app.use(routes.routes(), routes.allowedMethods());




app.listen(3000,()=>{
    console.log('启动成功')
})
